-- GENERATED SPELL FOR [Bonechewer Hungerer] --


function spell0_17259(pUnit, Event) --@Demoralizing Shout,Self--
pUnit:FullCastSpellOnTarget(16244,pUnit)
pUnit:RegisterEvent('Sorts_17259', 30284, 1)
end

function spell1_17259(pUnit, Event) --@Disarm,n/a--
pUnit:FullCastSpellOnTarget(6713,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_17259', 5308, 1)
end

function spell2_17259(pUnit, Event) --@Strike,n/a--
pUnit:FullCastSpellOnTarget(14516,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_17259', 597, 1)
end

function Sorts_17259(pUnit, Event)
local choix_sorts_17259 = math.random(0, 2)
if choix_sorts_17259 == 0 then
pUnit:RegisterEvent('spell0_17259', 1, 1)
end
if choix_sorts_17259 == 1 then
pUnit:RegisterEvent('spell1_17259', 1, 1)
end
if choix_sorts_17259 == 2 then
pUnit:RegisterEvent('spell2_17259', 1, 1)
end
end

function mob17259_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_17259', math.random(1500, 3000), 1)
end

function mob17259_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob17259_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob17259_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(17259, 1, 'mob17259_Action')
RegisterUnitEvent(17259, 2, 'mob17259_Leave')
RegisterUnitEvent(17259, 3, 'mob17259_Kill')
RegisterUnitEvent(17259, 4, 'mob17259_Die')
